package ch.kerbtier.malurus.components;

import java.util.ArrayList;
import java.util.Collections;
import java.util.List;

import ch.kerbtier.malurus.Component;
import ch.kerbtier.malurus.coreimpl.CiCompositeComponent;

public class Rows extends CiCompositeComponent {
	
	private List<Component> components = new ArrayList<Component>();
	
	public Rows add(Component c){
		register(c);
		components.add(c);
		return this;
	}

	public Rows remove(Component c){
		unregister(c);
		components.remove(c);
		return this;
	}
	
	public List<Component> getRows(){
		return Collections.unmodifiableList(components);
	}
}
